﻿using PcProject.Domain.Models.Entities;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace PcProject.Domain.IRepository
{
    public interface IOrderRepository
    {
        /// <summary>
        /// 订单显示查询分页
        /// </summary>
        /// <param name="number">查询参数</param>
        /// <param name="pageIndex">页数</param>
        /// <param name="pageSize">每页条数</param>
        /// <param name="totalCount">总条数</param>
        /// <returns></returns>
        List<OrderAll> GetOrdersAsync(string number, int pageIndex, int pageSize, out int totalCount);

        /// <summary>
        /// 订单添加
        /// </summary>
        /// <param name="obj">参数</param>
        /// <returns></returns>
        Task<int> InserAsync(Orders obj);

        /// <summary>
        /// 订单删除
        /// </summary>
        /// <param name="id">主键</param>
        /// <returns></returns>
        Task<int> DeleAsync(int id);

        /// <summary>
        /// 订单反填
        /// </summary>
        /// <param name="id">主键</param>
        /// <returns></returns>
        Task<OrderAll> FillAsync(int id);

        /// <summary>
        /// 订单修改
        /// </summary>
        /// <param name="obj">参数</param>
        /// <returns></returns>
        Task<int> UptAsync(Orders obj);

    }
}
